﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

public partial class 管理员_登录_注册 : System.Web.UI.Page
{
    protected void Page_Load(object sender, EventArgs e)
    {

    }
    protected void Button1_Click(object sender, EventArgs e)
    {
        string id = TextBox1.Text.Trim();
        string ps = TextBox2.Text.Trim();
        Users tmp = new Users();
        tmp.id = id;
        tmp.ps = ps;
        int result = tmp.Addoneuser(tmp);
        if(result>0)
        {
            Response.Write("<script>alert(\"恭喜你，注册成功！！\")</script>");
        }
        else
        {
            Response.Write("<script>alert(\"恭喜你，注册失败！！\")</script>");
        }
    }
}